<?php /* Smarty version 2.6.12, created on 2008-10-30 11:03:59
         compiled from modules/Customer_Reviews/reviews.tpl */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'strip_tags', 'modules/Customer_Reviews/reviews.tpl', 6, false),array('modifier', 'escape', 'modules/Customer_Reviews/reviews.tpl', 6, false),array('modifier', 'default', 'modules/Customer_Reviews/reviews.tpl', 32, false),array('modifier', 'replace', 'modules/Customer_Reviews/reviews.tpl', 32, false),)), $this); ?>
<?php func_load_lang($this, "modules/Customer_Reviews/reviews.tpl","err_filling_form,lbl_your_name,lbl_your_message,lbl_customer_reviews,lbl_author,lbl_unknown,lbl_unknown,txt_no_customer_reviews,lbl_add_your_review,lbl_your_name,lbl_your_message,lbl_add_review"); ?><tr style="display:none">
<td>
<script type="text/javascript">
<!--
var lbl_err_filling_form = "<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['err_filling_form'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp) : smarty_modifier_strip_tags($_tmp)))) ? $this->_run_mod_handler('escape', true, $_tmp, 'javascript') : smarty_modifier_escape($_tmp, 'javascript')); ?>
";
var required_review_Fields = [
                		["review_author", "<?php echo ((is_array($_tmp=$this->_tpl_vars['lng']['lbl_your_name'])) ? $this->_run_mod_handler('escape', true, $_tmp, 'javascript') : smarty_modifier_escape($_tmp, 'javascript')); ?>
"],
		                ["review_message", "<?php echo ((is_array($_tmp=$this->_tpl_vars['lng']['lbl_your_message'])) ? $this->_run_mod_handler('escape', true, $_tmp, 'javascript') : smarty_modifier_escape($_tmp, 'javascript')); ?>
"],
		            ];
<?php echo '
function check_reviews_form() {
	var result;

	result = checkRequired(required_review_Fields);
	if (result) {
		document.getElementById(\'reviewform\').submit();		
	}
}
'; ?>

-->
</script>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/include_js.tpl", 'smarty_include_vars' => array('src' => "check_required_fields_js.js")));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
</td>
</tr>
<tr>
	<td colspan="2"><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/subheader.tpl", 'smarty_include_vars' => array('title' => $this->_tpl_vars['lng']['lbl_customer_reviews'])));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?></td>
</tr>
<?php if ($this->_tpl_vars['reviews'] != ""):  $_from = $this->_tpl_vars['reviews']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['r']):
?>
<tr>
	<td colspan="2"><br /><b><?php echo $this->_tpl_vars['lng']['lbl_author']; ?>
: <?php echo ((is_array($_tmp=@$this->_tpl_vars['r']['email'])) ? $this->_run_mod_handler('default', true, $_tmp, @$this->_tpl_vars['lng']['lbl_unknown']) : smarty_modifier_default($_tmp, @$this->_tpl_vars['lng']['lbl_unknown'])); ?>
</b><br /><?php echo ((is_array($_tmp=$this->_tpl_vars['r']['message'])) ? $this->_run_mod_handler('replace', true, $_tmp, "\n", "<br />") : smarty_modifier_replace($_tmp, "\n", "<br />")); ?>
<br /><br /></td>
</tr>
<?php endforeach; endif; unset($_from);  else: ?>
<tr>
	<td colspan="2" align="center"><br/><?php echo $this->_tpl_vars['lng']['txt_no_customer_reviews']; ?>
</td>
</tr>
<?php endif;  if (( $this->_tpl_vars['config']['Customer_Reviews']['writing_reviews'] == 'A' ) || ( $this->_tpl_vars['login'] != "" && $this->_tpl_vars['config']['Customer_Reviews']['writing_reviews'] == 'R' )): ?>
<tr>
	<td colspan="2"><br /><b><font class="ProductDetailsTitle"><?php echo $this->_tpl_vars['lng']['lbl_add_your_review']; ?>
</font></b></td>
</tr>
<tr>
	<td colspan="2">

<form method="post" action="product.php?mode=review&amp;productid=<?php echo $this->_tpl_vars['product']['productid']; ?>
" id="reviewform">
<input type="hidden" name="productid" value='<?php echo $this->_tpl_vars['product']['productid']; ?>
' />
<table width="100%" cellpadding="2" cellspacing="0">
<tr>
	<td colspan="3"><img src="<?php echo $this->_tpl_vars['ImagesDir']; ?>
/spacer.gif" width="1" height="3" alt="" /></td>
</tr>
<tr>
	<td width="20%" class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_your_name']; ?>
:</td>
	<td width="10" align="center"><font class="Star">*</font></td>
	<td width="80%"><input type="text" size="24" name="review_author" id="review_author"<?php if ($this->_tpl_vars['login'] != ""): ?> value="<?php echo ((is_array($_tmp=$this->_tpl_vars['customer_info']['firstname'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
 <?php echo ((is_array($_tmp=$this->_tpl_vars['customer_info']['lastname'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
 (<?php echo ((is_array($_tmp=$this->_tpl_vars['customer_info']['email'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
)"<?php else: ?> value="<?php echo ((is_array($_tmp=$this->_tpl_vars['review']['author'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
"<?php endif; ?> /><?php if ($this->_tpl_vars['review']['author'] == "" && $this->_tpl_vars['review']['error'] != ""): ?><font class="Star">&lt;&lt;</font><?php endif; ?>
	</td>
</tr>
<tr>
	<td class="FormButton"><?php echo $this->_tpl_vars['lng']['lbl_your_message']; ?>
:</td>
	<td align="center"><font class="Star">*</font></td>
	<td>

	<table cellpadding="0" cellspacing="0">
	<tr>
		<td>
		<textarea cols="40" rows="4" name="review_message" id="review_message"><?php echo ((is_array($_tmp=$this->_tpl_vars['review']['message'])) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
</textarea>
		</td>
		<?php if ($this->_tpl_vars['review']['message'] == "" && $this->_tpl_vars['review']['error'] != ""): ?>
		<td align="left"><font class="Star">&lt;&lt;</font></td>
		<?php endif; ?>
	</tr>
	</table>

	</td>
</tr>
<?php $this->assign('antibot_err', $this->_tpl_vars['review']['antibot_err']);  if ($this->_tpl_vars['active_modules']['Image_Verification'] && $this->_tpl_vars['show_antibot']['on_reviews'] == 'Y'):  $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "modules/Image_Verification/spambot_arrest.tpl", 'smarty_include_vars' => array('mode' => 'simple','id' => $this->_tpl_vars['antibot_sections']['on_reviews'])));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
  endif; ?>
<tr>
	<td colspan="3"><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "buttons/button.tpl", 'smarty_include_vars' => array('button_title' => $this->_tpl_vars['lng']['lbl_add_review'],'style' => 'button','href' => "javascript: check_reviews_form();",'type' => 'input')));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?></td>
	
</tr>
</table>
</form>

	</td>
</tr>
<?php endif; ?>
